package edu.cmu.ece.ds.droidchat.message;

import java.io.Serializable;

/**
 * DroidChatMessage is any message sent between the DroidChat user and the
 * server
 */

public class DroidChatMessage implements Serializable {
	/**
	 *
	 */
	private static final long serialVersionUID = -3349826615192103064L;

	private int messageType;

	public static final int SERVER_HEARTBEAT = 1;
	public static final int CLIENT_LOGIN = 2;
	public static final int CLIENT_LOGIN_RESPONSE = 3;
	public static final int CLIENT_REGISTER = 4;
	public static final int CLIENT_REGISTER_RESPONSE = 5;
	public static final int CLIENT_PUBLIC_KEY = 6;
	public static final int UPDATE_LOCATION = 7;
	public static final int NEIGHBOR_INFO = 8;
	public static final int CHAT_INVITATION = 9;
	public static final int CHAT_INVITATION_RESPONSE = 10;
	public static final int CREATE_SESSION_INFO_REQUEST = 11;
	public static final int CREATE_SESSION_INFO_RESPONSE = 12;
	public static final int CREATE_SESSION_INVITATION = 13;
	public static final int CREATE_SESSION_RESPONSE_INVITATION = 14;
	public static final int ENC_CREATE_SESSION_INVITATION = 15;
	public static final int CHAT_MESSAGE = 16;
	public static final int CREATE_SESSION_KEY = 17;
	public static final int LOGOUT_COMMAND_FROM_SERVER = 18;
	public static final int LOGOUT_REQUEST_FROM_CLIENT = 19;
	public static final int DUMMY_FORCE_SSL_HANDSHAKE = 20;
	public static final int CREATE_SESSION = 21;
	public static final int REPORT_NEIGHBOR = 22;
	public static final int REPORT_KEEPALIVE = 23;
	public static final int ENC_CREATE_SESSION_RESPONSE_INVITATION = 24;
	
	public DroidChatMessage(int type) {
		messageType = type;
	}

	public String toString() {
		return Integer.toString(messageType);
	}
}
